<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<script src="js/mui.min.js"></script>
		<link href="css/mui.min.css" rel="stylesheet" />
		<link rel="stylesheet" type="text/css" href="css/sub.css" />
		<link rel="stylesheet" type="text/css" href="css/detail.css" />
		<script type="text/javascript" charset="utf-8">
			mui.init();
		</script>
	</head>
	<body>
		<header class="mui-bar mui-bar-nav detail">
	       <a class="mui-action-back mui-pull-left icon-left"></a>
	       <h1 class="detail-tit mui-ellipsis mui-pull-left">话题标题</h1>
	       <a href="" class="mui-pull-right icon-serve" style="font-size: .64rem;"></a>
	       <a href="" class="mui-pull-right icon-share mr24" style="font-size: .64rem;"></a>
	   </header>
		<div class="mui-content">
			<!--S头部信息-->
			<div id="content-header">
				<div class="nsd-header">
					<h1 class="mod-title-30 mui-ellipsis">话题标题</h1>
					<div class="nsd-header-img mt18"><img src="http://placehold.it/90x90" alt="" /></div>
					<p class="mod-title-24 mt6">作者昵称</p>
					<p class="mod-detail-22 mt6">2014-02-02</p>
				</div>
			</div>
			<!--E头部信息-->
			<!--内容详情部分-->
			<div class="detail-content bg-fff mt30" id="conWrap">
				 <div class="nsd-body">
				 	<div class="nsd-item">
				 		<p class="mod-title-24 fontc0">2017-02-02</p>
				 		<div class="nsd-icon">
				 			<img src="img/static/time0.png"/>
				 		</div>
				 		<p class="mod-info-24">图文图文图文图文图文图文图文图文图文图文图文图文图文 图文图文图文图文图文图文。图文图文图文图文图文图文图文图</p>
				 		<div class="nsd-item-imgs">
				 			<img src="http://placehold.it/500x90"/>
				 		</div>
				 	</div>
				 	<div class="nsd-item">
				 		<p class="mod-title-24 fontc1">2017-02-02</p>
				 		<div class="nsd-icon">
				 			<img src="img/static/time1.png"/>
				 		</div>
				 		<p class="mod-info-24">图文图文图文图文图文图文图文图文图文图文图文图文图文 图文图文图文图文图文图文。图文图文图文图文图文图文图文图</p>
				 		<div class="nsd-item-imgs">
				 			<img src="http://placehold.it/500x90"/>
				 		</div>
				 	</div>
				 	<div class="nsd-item">
				 		<p class="mod-title-24 fontc2">2017-02-02</p>
				 		<div class="nsd-icon">
				 			<img src="img/static/time2.png"/>
				 		</div>
				 		<p class="mod-info-24">图文图文图文图文图文图文图文图文图文图文图文图文图文 图文图文图文图文图文图文。图文图文图文图文图文图文图文图</p>
				 		<div class="nsd-item-imgs">
				 			<img src="http://placehold.it/500x90"/>
				 		</div>
				 	</div>
				 	<div class="nsd-item">
				 		<p class="mod-title-24 fontc3">2017-02-02</p>
				 		<div class="nsd-icon">
				 			<img src="img/static/time3.png"/>
				 		</div>
				 		<p class="mod-info-24">图文图文图文图文图文图文图文图文图文图文图文图文图文 图文图文图文图文图文图文。图文图文图文图文图文图文图文图</p>
				 		<div class="nsd-item-imgs">
				 			<img src="http://placehold.it/500x90"/>
				 		</div>
				 	</div>
				 </div>
			</div>
			<!--内容详情部分-->
			<!--我要评论-->
			<!--<div class="nsd-comment mt30">
				<button class="comment-btn">我要评论</button>
				<div class="mt30" id="gkpjwrap">
				</div>
			</div>-->
			<!--我要评论-->
		</div>
		<!--脚部-->
		<nav class="mui-bar mui-bar-tab detail-footer">
		<h1 class="phone-num mui-pull-left">400-8819-520</h1>
		<a href="#" class="footer-btn mui-pull-right">我也要写</a>
		<div class="mui-pull-right mt30 mr24">
			<i class="icon-like mr6"></i>
			<i class="icon-comment mr6"></i>
			<i class="icon-collect mr6"></i>
		</div>
		</nav>
		<script type="text/html" id="conJs">
			<div class="nsd-header">
				<h1 class="mod-title-30 mui-ellipsis">{{title}}</h1>
				<div class="nsd-header-img mt18"><img src="{{uportrait}}?imageView2/1/w/90/h/90" alt="" /></div>
				<p class="mod-title-24 mt6">{{uname}}</p>
				<p class="mod-detail-22 mt6">2014-02-02</p>
			</div>
		</script>
		<script type="text/html" id="nsJs">
			 <div class="nsd-body">
			 	{{each details as item index}}
				 	<div class="nsd-item">
				 		<p class="mod-title-24 fontc0">2017-02-02</p>
				 		<div class="nsd-icon">
				 			<img src="img/static/time0.png"/>
				 		</div>
				 		<p class="mod-info-24">{{item.content}}</p>
				 		<div class="nsd-item-imgs">
				 			{{each item.img as imgitem }}
				 			<img src="{{imgitem}}?imageView2/1/w/500"/>
				 			{{/each}}
				 		</div>
				 	</div>
			 	{{/each}}
			 </div>
		</script>
		<!--顾客评价-->
		<script type="text/html" id="gkpjJs">
			<div class="comment-wrap">
				{{ each arr as item index }}
				<div class="comment">
					<div class="comment-header mui-clearfix">
						<div class="comment-header-img mui-pull-left">
							<img src="http://placehold.it/99x99"/>
						</div>
						<div class="comment-header-con mui-pull-left">
							<h1 class="mod-title-24 mui-ellipsis">用户名</h1>
							<div class="mod-detail-22 mt12">
								<i class="icon-star"></i><i class="icon-star"></i><i class="icon-star"></i><i class="icon-star"></i>
							</div>
							<p class="mod-info-20 mui-ellipsis mt12"> 2017-06-31</p>
						</div>
					</div>
					<div class="comment-body">
						<p class="mod-info-20 mui-ellipsis-2">评价内容评价评价内容评评价内容评内容评价内容评价内容评价内容评价内容评价内容评价内容，评价内容评价内容评价内容评价内容评价内容评价内容 评价内容评价内容评价内容。评价内容显示两排</p>
						<div class="comment-body-imgs">
							<img src="http://placehold.it/150x150"/>
							<img src="http://placehold.it/150x150"/>
							<img src="http://placehold.it/150x150"/>
						</div>
					</div>
				</div>
				{{/each}}
			</div>
		</script>
		<script src="js/artTemplate.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/mod.js" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript">
//			var arr =[1,2,3,4,5];
//			var data ={};
//			data["arr"]=arr;
//			var html =template("gkpjJs",data);
//			mui("#gkpjwrap")[0].innerHTML=html;
			mui.ajax("http://www.xhwed.com/xhwe.php/Forum/planDetails",{
				data:{"wy":getUrlParam("wy")},
				dataType:'json',//服务器返回json格式数据
				type:'post',//HTTP请求类型
				timeout:10000,//超时时间设置为10秒；
				success:function(data){
					console.log(data);
					var headhtml=template("conJs",data.result.user);
					mui("#content-header")[0].innerHTML=headhtml;
					var conhtml = template("nsJs",data.result);
					mui("#conWrap")[0].innerHTML=conhtml;
				},
				error:function(xhr,type,errorThrown){
					//异常处理；
					console.log(type);
				}
			});
		</script>
	</body>
	
	

</html>